package com.bbva.cbm.web.servlet.spring.operatoria;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.servlet.http.HttpSession;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.servlet.ModelAndView;

import cbm.commons.BaseController;
import ejb.com.bbva.cbm.service.OperativaServiceLocal;


public class ExtornoOperacionController extends BaseController{

	private OperativaServiceLocal operativaServiceLocal;
	@Autowired
	public void setOperativaServiceLocal(OperativaServiceLocal operativaServiceLocal) {
		this.operativaServiceLocal = operativaServiceLocal;
	}

	public ModelAndView actualizarEstadoImpresion(HttpServletRequest request, HttpServletResponse response){
		return null;
	}

	public ModelAndView buscar(HttpServletRequest request, HttpServletResponse response){
		return null;
	}

	public ModelAndView open(HttpServletRequest request, HttpServletResponse response){
		HttpSession session = null;
		String paginaSig = resources.getString("extonar_operacion");
		
		try {
			session = request.getSession();
			session.setAttribute("tiposOperacion", operativaServiceLocal.obtenerTiposOperacion());
			
		} catch (Exception e) {
			e.printStackTrace();
		}
		
		return new ModelAndView(paginaSig);
	}

	public ModelAndView save(HttpServletRequest request, HttpServletResponse response){
		return null;
	}
}
